﻿using System.IO;
using System.Web.Script.Serialization;

namespace WebDiagnostics
{
    public abstract class Diagnosis
    {
        public virtual void Render(TextWriter writer)
        {
            var serializer = new JavaScriptSerializer();
            var serializedDiagnosis = serializer.Serialize(this);

            writer.WriteLine(serializedDiagnosis);
        }
    }
}